---
title: Face Liveness Troubleshooting
description: Troubleshoot your issues with the Amplify UI FaceLivenessDetector component.
supportedFrameworks: react|android|swift
---

import { InlineFilter } from '@/components/InlineFilter';
import TroubleshootAndroid from './troubleshooting-android.mdx';
import TroubleshootReact from './troubleshooting-react.mdx';
import TroubleshootSwift from './troubleshooting-swift.mdx';

The following issues are presented with corresponding troubleshooting steps. Please check them out in case you run into issues like these -- if the remedies don't work, please file an issue in our GitHub repositories.

### Error: Cognito user pool does not allow access to unauthenticated identities

First, make sure you have followed the [prerequisites for setting up Amplify resources](../liveness#step-1-configure-auth). Second, you can also go into the Cognito identity pool configured in your Amplify app, edit it and select the checkbox labeled "Enable access to unauthenticated identities" -- then save the changes. Finally, ensure that the configuration file -- `aws-exports.js` on web or `amplifyconfiguration.json` on mobile -- contains the name of the correct identity pool.

### Error: Server error - Session not found 

1. Ensure that the AWS region you are using to create the liveness session in your backend is the same as the one used within your app.
2. Ensure that the session ID returned from the backend when creating the session is the same as the one created on initialization of the Liveness UI. Note: session IDs can only be used once. You must create a new session to allow users to retry the Liveness check.

### Error: AccessDeniedError when calling Rekognition APIs (CreateFaceLivenessSession, etc.)

Full error: `An error occurred (AccessDeniedException) when calling the CreateFaceLivenessSession`.

Make sure you are using a supported AWS region. Please refer to [Liveness supported regions](https://aws.amazon.com/rekognition/face-liveness/#FAQs) documentation.

### Error: Connection time out

The websocket connection to the Rekognition streaming service will time out after 5 seconds if a connection is not made. This often happens due to a slow network connection. If your users encounter this issue, prompt them to try again at a different time or using a different network connection.

### No result when GetFaceLivenessSessionResults is called

Ensure that the session ID returned from the backend when creating the session is the same as the one created on initialization of the Liveness UI. Note: session IDs can only be used once. You must create a new session to allow users to retry the Liveness check.

<InlineFilter filters={['android']}>
  <TroubleshootAndroid />
</InlineFilter>
<InlineFilter filters={['react']}>
  <TroubleshootReact />
</InlineFilter>
<InlineFilter filters={['swift']}>
  <TroubleshootSwift />
</InlineFilter>

### I am unable to use the Amplify CLI and/or CloudFormation. Can I still use the FaceLivenessDetector?

Yes, this use case is supported.  Please select "Self Managed Cognito Resource" in [Step 1 of the setup](../liveness#step-1-configure-auth).

<InlineFilter filters={['react']}>
### InvalidSignatureException: Signature not yet current

The signature verification on the Rekognition streaming websocket connection was rejected due to a clock skew greater than or equal to 5 minutes. Clock skew represents the difference between a user's device time and AWS server time, and any clock skew of 5 minutes or larger will be rejected by default. Below are some common reasons for encountering this error along with suggestions for resolving them.
1. **The time on the user's device is inaccurate.** Ensure that the date and time on the user's device are accurate and match their time zone.
2. **User is in a new time zone that is not reflected on their device, or living between and frequently switching time zones.** If users cannot adjust their device time, you can pass `systemClockOffset` to the [`FaceLivenessDetectorCore` config](../liveness#facelivenessdetectorcoreconfig), which will be applied as an offset in milliseconds to the AWS server time. See an example [here](../liveness/customization#system-clock-offset).
</InlineFilter>